package ltd.bugs.cute.channel.model;

import java.io.Serializable;

import org.apache.ibatis.type.Alias;

@Alias("Channel")
public class Channel implements Serializable {

  private static final long serialVersionUID = 1974856758728178726L;

  // 主键
  private long id;
  // 通道名称
  private String name;
  // 通道SPI实现节点
  private String extName;
  // 通道状态
  private int status;
  // 通道类型
  private int type;
  // 权重，该字段没有持久化到数据库，仅仅为了ChannelSelector中设置为ChannelConfig的weight使用
  private int weight;
  // 备注信息
  private String remark;

  public static final int STATUS_ENABLE = 1;
  public static final int STATUS_DISABLE = 0;

  public long getId() {
    return id;
  }

  public void setId(long id) {
    this.id = id;
  }

  public String getName() {
    return name;
  }

  public void setName(String name) {
    this.name = name;
  }

  public String getExtName() {
    return extName;
  }

  public void setExtName(String extName) {
    this.extName = extName;
  }

  public int getStatus() {
    return status;
  }

  public void setStatus(int status) {
    this.status = status;
  }

  public int getType() {
    return type;
  }

  public void setType(int type) {
    this.type = type;
  }

  public int getWeight() {
    return weight;
  }

  public void setWeight(int weight) {
    this.weight = weight;
  }

  public String getRemark() {
    return remark;
  }

  public void setRemark(String remark) {
    this.remark = remark;
  }
}
